package org.demo.patten.template_method;

import java.util.Arrays;
import java.util.List;

/**
 * @author zhuj
 * @date 2025/3/29
 * @apiNote
 */
public class PdfExporter extends ReportExporter {
    protected List<String> queryData() {
        System.out.println("查询数据库，获取报表数据...");
        return Arrays.asList("记录A", "记录B");
    }
    protected String format(List<String> data) {
        System.out.println("格式化为PDF文档...");
        return "PDF格式内容";
    }
    protected String writeToFile(String content) {
        System.out.println("写入PDF文件...");
        return "/export/report.pdf";
    }
}
